package edu.friday.service;

import edu.friday.common.result.TreeSelect;
import edu.friday.model.SysMenu;
import edu.friday.model.vo.RouterVo;
import edu.friday.model.vo.SysMenuVO;

import java.util.List;
import java.util.Set;

public interface ISysMenuService {
    Set<String> selectMenuPermissionByUserId(Long userId);

    List<SysMenu> selectMenuList(SysMenuVO sysMenuVO, Long userId);

    List<SysMenu> selectMenuList(Long userId);

    SysMenu selectMenuById(Long menuId);

    boolean insertMenu(SysMenuVO sysMenuVO);

    String checkMenuNameUnique(SysMenuVO sysMenuVO);

    boolean updateMenu(SysMenuVO sysMenuVO);

    boolean deleteMenuById(Long menuId);

    boolean hasChildByMenuId(Long menuId);

    boolean checkMenuExistRole(Long menuId);

    List<TreeSelect> buildMenuTreeSelect(List<SysMenuVO> sysMenuVOS);

    List<Long> selectMenuListByRoleId(Long roleId);

    List<SysMenuVO> selectMenuTreeByUserId(Long userId);

    List<SysMenuVO> getChildPerms(List<SysMenuVO> menuVOS, int parentId);

    List<RouterVo> buildMenus(List<SysMenuVO> menus);
}
